package com.learn.hibernatevalidator.chapter02.containerelement.custom;

import jakarta.validation.valueextraction.ExtractedValue;
import jakarta.validation.valueextraction.ValueExtractor;

/**
 * @author: liyf
 * @create: 2024-12-21 20:44
 **/
public class GearBoxValueExtractor implements ValueExtractor<GearBox<@ExtractedValue ?>> {
    @Override
    public void extractValues(GearBox<?> gearBox, ValueReceiver valueReceiver) {
        valueReceiver.value(null, gearBox.getGear());
    }
}
